import Base: (+), (-)

(-)(x::T, y::Date)     where T<:SimpleClock = Clock(x) - Clock(y)
(-)(x::Date, y::T)     where T<:SimpleClock = Clock(x) - Clock(y)
(-)(x::T, y::DateTime) where T<:SimpleClock = Clock(x) - Clock(y)
(-)(x::DateTime, y::T) where T<:SimpleClock = Clock(x) - Clock(y)
(-)(x::T, y::Time24)   where T<:SimpleClock = Clock(x) - y
(-)(x::Time24, y::T)   where T<:SimpleClock = throw(ErrorException("Time - Clock is invalid. Use Clock - Time"))

(+)(x::Date, y::T)     where T<:Duration = DateTime(C;ock(x) + y)
(+)(x::T, y::Date)     where T<:Duration = DateTime(x + Clock(y))
(+)(x::DateTime, y::T) where T<:Duration = DateTime(Clock(x) + y)
(+)(x::T, y::DateTime) where T<:Duration = DateTime(x + Clock(y))
(+)(x::T, y::Time24)   where T<:Duration = Duration(x + y)
(+)(x::Time24, y::T)   where T<:Duration = Duration(x + y)

(-)(x::Time24, y::T) where T<:NanosecondBasedGrain = Nanoseconds(value(x) - nanoseconds(y))
(+)(x::Time24, y::T) where T<:NanosecondBasedGrain = Nanoseconds(value(x) + nanoseconds(y))
(-)(x::T, y::Time24) where T<:NanosecondBasedGrain = Nanoseconds(nanoseconds(x) - value(y))
(+)(x::T, y::Time24) where T<:NanosecondBasedGrain = Nanoseconds(nanoseconds(x) + value(y))

(-)(x::Date, y::T)     where T<:AbstractGranularity = Clock(x) - y
(-)(x::DateTime, y::T) where T<:AbstractGranularity = Clock(x) - y
(-)(x::Time24, y::T)   where T<:AbstractGranularity = Clock(x) - y

(+)(x::Date, y::T)     where T<:AbstractGranularity = Clock(x) + y
(+)(x::DateTime, y::T) where T<:AbstractGranularity = Clock(x) + y
(+)(x::Time24, y::T)   where T<:AbstractGranularity = Clock(x) + y
(+)(x::T, y::Date)     where T<:AbstractGranularity = x + Clock(y)
(+)(x::T, y::DateTime) where T<:AbstractGranularity = x + Clock(y)
(+)(x::T, y::Time24)   where T<:AbstractGranularity = x + Clock(y)

(+)(x::Time24, y::Base.Dates.Day) = x + Days(y)
(+)(x::Base.Dates.Day, y::Time24) = Days(x) + y
(-)(x::Time24, y::Base.Dates.Day) = x - Days(y)
(-)(x::Base.Dates.Day, y::Time24) = Days(x) - y
